package com.ship.dispatch.controller;

import com.ship.common.core.web.domain.JsonResult;
import com.ship.dispatch.bpm.service.ProcessInstanceService;
import com.ship.dispatch.bpm.service.TaskService;
import com.ship.dispatch.service.ContractServiceClient;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;

@RestController
@RequestMapping("/dispatchTest")
public class TestController {

    @Autowired
    private ContractServiceClient contractServiceClient;
    @Autowired
    private ProcessInstanceService processInstanceService;
    @Autowired
    private TaskService taskService;

    @GetMapping("/detail")
    public JsonResult<List<Map<String, Object>>> detail(@RequestParam("id") Long id) {
        return contractServiceClient.detail(id);
    }
}
